Gbsma601 (#20)

* Delete AccDec_7ServoBackandForth6Ftn.ino

* Delete AccDec_10Servos_7LED_6Ftn.ino

* Delete AccDec_13Servos_4LED_6Ftn.ino

* Delete AccDec_15Servos_2LED_6Ftn.ino

* Delete AccDec_17LED_1Ftn.ino

* Delete AccDec_17LED_6Ftn.ino

* Delete AccDec_7Servos_10LED_6Ftn.ino

* Delete Dec_10Serv_7LED_6Ftn.ino

* Delete Dec_13Serv_4LED_6Ftn.ino

* Delete Dec_15Serv_2LED_6Ftn.ino

* Delete Dec_17LED_1Ftn.ino

* Delete Dec_17LED_6Ftn.ino

* Delete Dec_2Mot_12LED_1Srv_6Ftn.ino

* Delete Dec_2Mot_3LED_TrigAud.ino

* Delete Dec_2Mot_4LED_Aud_8Ftn.ino

* Delete Dec_7Serv_10LED_6Ftn.ino

* Delete Dec_Dir_and_Fade.ino

* Delete Dec_SMA12_LED_Groups.ino

* Delete Dec_Stepper_6Ftn.ino

* Delete SMA 6.0 Release Notes.rtf

* Add files via upload

* Delete Dec_2Mot_12LED_1Srv_6Ftn.ino

* Delete Dec_2Mot_3LED_TrigAud.ino

* Delete Dec_2Mot_4LED_Aud_8Ftn.ino

* Add files via upload

* Delete SMA 6.01 Release Notes.rtf

* Add files via upload
This commit is contained in:
Geoff Bunza
2018-08-07 14:55:33 -07:00
committed by Alex Shepherd
parent 15da83c411
commit 6dca23bc27
20 changed files with 292 additions and 181 deletions

17
examples/SMA/AccDec_17LED_1Ftn/AccDec_17LED_1Ftn.ino Executable file → Normal file
View File

@@ -1,5 +1,5 @@
// Production 17 Switch Acessory DCC Decoder AccDec_17LED_1Ftn.ino
// Version 6.0 Geoff Bunza 2014,2015,2016,2017,2018
// Version 6.01 Geoff Bunza 2014,2015,2016,2017,2018
// Now works with both short and long DCC Addesses for CV Control Default 24 (LSB CV 121 ; MSB CV 122)
// ACCESSORY DECODER DEFAULT ADDRESS IS 40 (MAX 40-56 SWITCHES)
// ACCESSRY DECODER ADDRESS CAN NOW BE SET ABOVE 255
@@ -56,12 +56,15 @@ CVPair FactoryDefaultCVs [] =
{CV_MULTIFUNCTION_EXTENDED_ADDRESS_MSB, 0},
{CV_MULTIFUNCTION_EXTENDED_ADDRESS_LSB, 0},
// Speed Steps don't matter for this decoder
// ONLY uncomment 1 CV_29_CONFIG line below as approprate DEFAULT IS SHORT ADDRESS
// {CV_29_CONFIG, 0}, // Short Address 14 Speed Steps
{CV_29_CONFIG, CV29_F0_LOCATION}, // Short Address 28/128 Speed Steps
// {CV_29_CONFIG, CV29_EXT_ADDRESSING | CV29_F0_LOCATION}, // Long Address 28/128 Speed Steps
// {CV_29_CONFIG, 0}, // Short Address 14 Speed Steps
// {CV_29_CONFIG, CV29_F0_LOCATION}, // Short Address 28/128 Speed Steps
// {CV_29_CONFIG, CV29_EXT_ADDRESSING | CV29_F0_LOCATION}, // Long Address 28/128 Speed Steps
{CV_29_CONFIG,CV29_ACCESSORY_DECODER|CV29_OUTPUT_ADDRESS_MODE|CV29_F0_LOCATION}, // Accesory Decoder Short Address
// {CV_29_CONFIG, CV29_ACCESSORY_DECODER|CV29_OUTPUT_ADDRESS_MODE|CV29_EXT_ADDRESSING | CV29_F0_LOCATION}, // Accesory Decoder Long Address
{CV_DECODER_MASTER_RESET, 0},
{CV_To_Store_SET_CV_Address, SET_CV_Address&0xFF }, // LSB Set CV Address
{CV_To_Store_SET_CV_Address+1,(SET_CV_Address>>8)&0x3F }, //MSB Set CV Address
@@ -105,7 +108,7 @@ void setup()
// Setup which External Interrupt, the Pin it's associated with that we're using and enable the Pull-Up
Dcc.pin(0, 2, 0);
// Call the main DCC Init function to enable the DCC Receiver
Dcc.init( MAN_ID_DIY, 600, FLAGS_OUTPUT_ADDRESS_MODE | FLAGS_DCC_ACCESSORY_DECODER, CV_To_Store_SET_CV_Address);
Dcc.init( MAN_ID_DIY, 601, FLAGS_OUTPUT_ADDRESS_MODE | FLAGS_DCC_ACCESSORY_DECODER, CV_To_Store_SET_CV_Address);
}
void loop()
{
@@ -116,4 +119,4 @@ extern void notifyDccAccTurnoutOutput( uint16_t Addr, uint8_t Direction, uint8_t
if ( Addr >= Accessory_Address && Addr < Accessory_Address+17) //Controls This_Decoder_Address+16
digitalWrite( ledpins[Addr-Accessory_Address], Direction );
}