Would it be possible to get this enabled for the A3400 IS?
If I read your post correctly, you are already making your own builds (in order to get the battery 3rd terminal hack working) ?
If so then you should be able to just add :
#define CAM_ALLOWS_USB_PORT_FORCING 1
to your platform_camera.h file, modify
my_kbd_read_keys() in your kbd.c file,and rebuild to resolve this. You can use the code in the kbd.c file for the A1200 as a model :
void my_kbd_read_keys() {
kbd_prev_state[0] = kbd_new_state[0];
kbd_prev_state[1] = kbd_new_state[1];
kbd_prev_state[2] = kbd_new_state[2];
_GetKbdState(kbd_new_state);
_kbd_read_keys_r2(kbd_new_state);
if (kbd_process() == 0) {
// we read keyboard state with _kbd_read_keys()
physw_status[0] = kbd_new_state[0];
physw_status[1] = kbd_new_state[1];
physw_status[2] = kbd_new_state[2];
} else {
// override keys
physw_status[0] = (kbd_new_state[0] | KEYS_MASK0) & (~KEYS_MASK0 | kbd_mod_state[0]);
physw_status[1] = (kbd_new_state[1] | KEYS_MASK1) & (~KEYS_MASK1 | kbd_mod_state[1]);
physw_status[2] = (kbd_new_state[2] | KEYS_MASK2) & (~KEYS_MASK2 | kbd_mod_state[2]);
}
#ifdef CAM_ALLOWS_USB_PORT_FORCING
if ( forced_usb_port ) physw_status[USB_IDX] = (physw_status[USB_IDX]& ~(SD_READONLY_FLAG)) | USB_MASK ;
else if (conf.remote_enable)
physw_status[USB_IDX] = physw_status[USB_IDX] & ~(SD_READONLY_FLAG | USB_MASK);
else physw_status[USB_IDX] = physw_status[USB_IDX] & ~SD_READONLY_FLAG;
#else
if (conf.remote_enable) physw_status[USB_IDX] = physw_status[USB_IDX] & ~(SD_READONLY_FLAG | USB_MASK);
else physw_status[USB_IDX] = physw_status[USB_IDX] & ~SD_READONLY_FLAG;
#endif
}
Sounds like you are working on a fun project - please post pictures and more details when you get a little farther along. If you need help with the stuff I posted above just let me know?