Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions lib/bus/iwm/iwm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -579,6 +579,7 @@ bool IRAM_ATTR iwmBus::serviceDiskII()
break;

case iwm_enable_state_t::on:
diskii_xface.d2_enable_seen |= diskii_xface.iwm_enable_states();
#ifdef DEBUG
new_track = IWM_ACTIVE_DISK2->get_track_pos();
if (old_track != new_track)
Expand Down
2 changes: 2 additions & 0 deletions lib/bus/iwm/iwm.h
Original file line number Diff line number Diff line change
Expand Up @@ -107,12 +107,14 @@ enum {
#define IWM_CTRL_RUN_ROUTINE 0x05
#define IWM_CTRL_DWNLD_ADDRESS 0x06
#define IWM_CTRL_DOWNLOAD 0x07
#define IWM_CTRL_CLEAR_ENSEEN 0x08

#define IWM_STATUS_STATUS 0x00
#define IWM_STATUS_DCB 0x01
#define IWM_STATUS_NEWLINE 0x02
#define IWM_STATUS_DIB 0x03
#define IWM_STATUS_UNI35 0x05
#define IWM_STATUS_ENSEEN 0x08

// class def'ns
class iwmFuji; // declare here so can reference it, but define in fuji.h
Expand Down
1 change: 1 addition & 0 deletions lib/bus/iwm/iwm_ll.h
Original file line number Diff line number Diff line change
Expand Up @@ -293,6 +293,7 @@ class iwm_diskii_ll : public iwm_ll

public:
QueueHandle_t iwm_write_queue;
uint8_t d2_enable_seen = 0;

// Phase lines and ACK handshaking
uint8_t iwm_phase_vector() { return (uint8_t)(GPIO.in1.val & (uint32_t)0b1111); };
Expand Down
2 changes: 2 additions & 0 deletions lib/device/iwm/fuji.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ iwmFuji::iwmFuji()

{ FUJICMD_RESET, [this]() { this->send_reply_packet(err_result); this->iwm_ctrl_reset_fujinet(); }}, // 0xFF
{ IWM_CTRL_RESET, [this]() { this->send_reply_packet(err_result); this->iwm_ctrl_reset_fujinet(); }}, // 0x00
{ IWM_CTRL_CLEAR_ENSEEN, [this]() { diskii_xface.d2_enable_seen = 0; err_result = SP_ERR_NOERROR; }},

{ FUJICMD_MOUNT_ALL, [&]() { err_result = (mount_all() ? SP_ERR_IOERROR : SP_ERR_NOERROR); }}, // 0xD7
{ FUJICMD_MOUNT_IMAGE, [&]() { err_result = iwm_ctrl_disk_image_mount(); }}, // 0xF8
Expand All @@ -91,6 +92,7 @@ iwmFuji::iwmFuji()

{ IWM_STATUS_DIB, [this]() { this->send_status_dib_reply_packet(); status_completed = true; }}, // 0x03
{ IWM_STATUS_STATUS, [this]() { this->send_status_reply_packet(); status_completed = true; }}, // 0x00
{ IWM_STATUS_ENSEEN, [this]() { data_len = 1; data_buffer[0] = diskii_xface.d2_enable_seen; }},

{ FUJICMD_DEVICE_ENABLE_STATUS, [this]() { this->send_stat_get_enable(); }}, // 0xD1
{ FUJICMD_GET_ADAPTERCONFIG_EXTENDED, [this]() { this->iwm_stat_get_adapter_config_extended(); }}, // 0xC4
Expand Down