Python LT8900 via SPI

Check-in [a1662e7ae5]
Login
Overview
Comment:Allow user to configure multi-transmit delay
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: a1662e7ae5e3aba0c39392b827f0eba8206d3170678ede18a33b5fe60c109dfd
User & Date: rkeene on 2020-04-27 13:38:43
Other Links: manifest | tags
Context
2020-04-27
13:44
Allow user to configure SPI parameters check-in: 831f49e143 user: rkeene tags: trunk
13:38
Allow user to configure multi-transmit delay check-in: a1662e7ae5 user: rkeene tags: trunk
13:33
Expose a mechanism for filling the chip FIFO, which otherwise requires privarte methods check-in: 5b2064ba1c user: rkeene tags: trunk
Changes

Modified __init__.py from [5bb68ba2bd] to [db9b618ade].

499
500
501
502
503
504
505
506

507
508
509
510
511

512
513
514
515
516
517
518
499
500
501
502
503
504
505

506
507
508
509
510

511
512
513
514
515
516
517
518







-
+




-
+








			if radio_status['packet_flag'] == 1:
				break
			time.sleep(0.1)

		return True

	def multi_transmit(self, message, channels, retries = 3):
	def multi_transmit(self, message, channels, retries = 3, delay = 0.1):
		for i in range(retries):
			for channel in channels:
				if not self.transmit(message, channel):
					return False
				time.sleep(0.1 / retries)
				time.sleep(delay / retries)
		return True

	def start_listening(self, channel):
		# Initialize the receiver
		self.put_register_bits('radio_state', {
			'tx_enabled': 0,
			'rx_enabled': 0,