Added in enhancements from Martin Pischky for 14 & 28 speed steps and merged in more examples from Geoff into the examples/SMA folder

This commit is contained in:
Alex Shepherd
2015-11-16 23:49:12 +13:00
parent 8f6fbdead1
commit f903b3ab53
19 changed files with 4062 additions and 47 deletions

7
examples/NmraDccExample_1/NmraDccExample_1.ino Executable file → Normal file
View File

@@ -12,7 +12,7 @@ struct CVPair
uint16_t CV;
uint8_t Value;
};
CVPair FactoryDefaultCVs [] =
{
{CV_ACCESSORY_DECODER_ADDRESS_LSB, 1},
@@ -93,7 +93,8 @@ void setup()
Dcc.pin(0, 2, 1);
// Call the main DCC Init function to enable the DCC Receiver
Dcc.init( MAN_ID_DIY, 10, FLAGS_OUTPUT_ADDRESS_MODE | FLAGS_DCC_ACCESSORY_DECODER, 0 );
Dcc.init( MAN_ID_DIY, 10, CV29_ACCESSORY_DECODER | CV29_OUTPUT_ADDRESS_MODE, 0 );
Serial.println("Init Done");
}
@@ -107,4 +108,4 @@ void loop()
FactoryDefaultCVIndex--; // Decrement first as initially it is the size of the array
Dcc.setCV( FactoryDefaultCVs[FactoryDefaultCVIndex].CV, FactoryDefaultCVs[FactoryDefaultCVIndex].Value);
}
}
}