108 lines
2.3 KiB
Plaintext
Raw Normal View History

2023-06-27 19:48:12 +03:00
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"id": "d9d52021-6ba8-48b2-8a0d-e434635c4085",
"metadata": {},
"outputs": [],
"source": [
"from RCCar import RCCar, Direction"
]
},
{
"cell_type": "code",
"execution_count": 2,
"id": "8c491527-223f-4acf-af27-bdb49689e576",
"metadata": {},
"outputs": [],
"source": [
"# Defining the car\n",
"car = RCCar()"
]
},
{
"cell_type": "code",
"execution_count": 3,
"id": "1a055dd5-1ff3-446d-a8e6-9217c1183f0f",
"metadata": {
"scrolled": true
},
"outputs": [
{
"name": "stderr",
"output_type": "stream",
"text": [
"call hackrf_set_sample_rate(2000000 Hz/2.000 MHz)\n",
"call hackrf_set_baseband_filter_bandwidth(3500000 Hz/3.500 MHz)\n",
"call hackrf_set_hw_sync_mode(0)\n",
"call hackrf_set_freq(27150000 Hz/27.150 MHz)\n",
"Stop with Ctrl-C\n",
" 3.9 MiB / 1.000 sec = 3.9 MiB/second, average power -3.6 dBfs\n",
" 1.1 MiB / 0.265 sec = 4.2 MiB/second, average power -4.6 dBfs\n",
"\n",
"Exiting...\n",
"Total time: 1.26459 s\n",
"hackrf_stop_tx() done\n",
"hackrf_close() done\n",
"hackrf_exit() done\n",
"fclose() done\n",
"exit\n"
]
},
{
"data": {
"text/plain": [
"'Left.complex'"
]
},
"execution_count": 3,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"# Moving to the left\n",
"car.move(Direction.LEFT.value)"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "758b7a2a-53fb-41aa-883c-d32a233cfd3f",
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": null,
"id": "20d0cd4a-211c-4b29-af95-3a8d270fcc5d",
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.3"
}
},
"nbformat": 4,
"nbformat_minor": 5
}