I would like to request support for automatic filament changers (AFC), specifically using my implementation found at https://github.com/jaysuk/BoxTurtle_RRF
I have a display that I have created that can be found here https://github.com/jaysuk/BoxTurtle_display and this implementation would be replicating its functionality.
As part of the implementation I use arrays and nested arrays. Typically the first level of items in the array is the unit number. The second level is the lane number and then after that it could be different features etc depending on the array name.
So to walk through how it works, firstly I would suggest only showing the AFC screen if global.AFC_unit_CAN_ids is present (its an array containing the CAN address of each unit). This global also gives you the quantity of units.
global.AFC_unit_total_lanes gives you the number of lanes per unit and is also an array. Off the shelf AFCs are currently 2 lane (nightowl) or 4 lane (boxturtle) however I have seen up to 10 lanes on a single unit so the display would have to be able to adjust to the correct number of lanes for the unit being displayed.
There would need to be a button that allows the unit number to be selected.
There would be a card for each lane. This would have the lane number above which starts are lane 0.
Each card would show whether the lane is loaded. This is found in global.AFC_lanes[unit_number][lane_number][0] and can be either true or false.
Next there would need to be an unload button. This would send the commane M98 P"0:/macros/Lane - Unload" A{tool_number}. The tool number can be looked up from the array global.AFC_lane_to_tool
Next would be a dropdown box that allows the filament type to be set. This could either be pulled from the internal DWC filament handling feature or from the file 0:/sys/filamentList.json
{
"listValues": [
"Brown PLA",
"Blue PLA",
"Pink PLA",
"Orange PLA"
]
}
When the filament is selected, this needs to update the value of global.AFC_lanes[unit_number][lane_number][4][0]
There would also be a button to mark the lane unloaded if the user has had to manually remove the filament. This would run M98 P"0:/macros/Lane - Mark Unloaded" A{tool_number}
Next there would be a button to measure the first length of the lane (between the switch after the extruder in that lane and the hub. This would run M98 P"0:/macros/Lane - Measure First" A{tool_number}
It may be a good idea to add a button to measure the overall length. This only needs to be done with one lane on the unit and would run `M98 P"0:/macros/Lane - Measure Main Length" A{tool_number}
We may also want to show what the first length and main length are for each lane. These can be found in global.AFC_lanes[unit_number][lane_number][1] (first length) and global.AFC_lanes[unit_number][lane_number][2] (full length).
Finally it may make sense to replicate the LED status for each lane. This would follow the colours set on the neopixels on the AFC (or would be the only way if the unit doesn't have neopixels). This can be found in global.AFC_LED_array[unit_number][lane_number]
Here are some pictures of the screen linked to above that (almost) follows the above description.

I would like to request support for automatic filament changers (AFC), specifically using my implementation found at https://github.com/jaysuk/BoxTurtle_RRF
I have a display that I have created that can be found here https://github.com/jaysuk/BoxTurtle_display and this implementation would be replicating its functionality.
As part of the implementation I use arrays and nested arrays. Typically the first level of items in the array is the unit number. The second level is the lane number and then after that it could be different features etc depending on the array name.
So to walk through how it works, firstly I would suggest only showing the AFC screen if global.AFC_unit_CAN_ids is present (its an array containing the CAN address of each unit). This global also gives you the quantity of units.
global.AFC_unit_total_lanes gives you the number of lanes per unit and is also an array. Off the shelf AFCs are currently 2 lane (nightowl) or 4 lane (boxturtle) however I have seen up to 10 lanes on a single unit so the display would have to be able to adjust to the correct number of lanes for the unit being displayed.
There would need to be a button that allows the unit number to be selected.
There would be a card for each lane. This would have the lane number above which starts are lane 0.
Each card would show whether the lane is loaded. This is found in global.AFC_lanes[unit_number][lane_number][0] and can be either true or false.
Next there would need to be an unload button. This would send the commane
M98 P"0:/macros/Lane - Unload" A{tool_number}. The tool number can be looked up from the array global.AFC_lane_to_toolNext would be a dropdown box that allows the filament type to be set. This could either be pulled from the internal DWC filament handling feature or from the file 0:/sys/filamentList.json
When the filament is selected, this needs to update the value of global.AFC_lanes[unit_number][lane_number][4][0]
There would also be a button to mark the lane unloaded if the user has had to manually remove the filament. This would run
M98 P"0:/macros/Lane - Mark Unloaded" A{tool_number}Next there would be a button to measure the first length of the lane (between the switch after the extruder in that lane and the hub. This would run
M98 P"0:/macros/Lane - Measure First" A{tool_number}It may be a good idea to add a button to measure the overall length. This only needs to be done with one lane on the unit and would run `M98 P"0:/macros/Lane - Measure Main Length" A{tool_number}
We may also want to show what the first length and main length are for each lane. These can be found in global.AFC_lanes[unit_number][lane_number][1] (first length) and global.AFC_lanes[unit_number][lane_number][2] (full length).
Finally it may make sense to replicate the LED status for each lane. This would follow the colours set on the neopixels on the AFC (or would be the only way if the unit doesn't have neopixels). This can be found in global.AFC_LED_array[unit_number][lane_number]
Here are some pictures of the screen linked to above that (almost) follows the above description.