Skip to content

Commit

Permalink
Finish v0.9.0
Browse files Browse the repository at this point in the history
  • Loading branch information
SillyFreak committed Sep 25, 2019
2 parents fb76e7b + 0bc7bcd commit 677a433
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 deletions.
8 changes: 4 additions & 4 deletions hedgehog/client/async_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -362,16 +362,16 @@ async def get_io_config(self, port: int) -> int:
assert response.port == port
return response.flags

async def configure_motor(self, port: int, config: motor.Config) -> int:
async def configure_motor(self, port: int, config: motor.Config) -> None:
await self.send(motor.ConfigAction(port, config))

async def configure_motor_dc(self, port: int) -> int:
async def configure_motor_dc(self, port: int) -> None:
await self.configure_motor(port, motor.DcConfig())

async def configure_motor_encoder(self, port: int, encoder_a_port: int, encoder_b_port: int) -> int:
async def configure_motor_encoder(self, port: int, encoder_a_port: int, encoder_b_port: int) -> None:
await self.configure_motor(port, motor.EncoderConfig(encoder_a_port, encoder_b_port))

async def configure_motor_stepper(self, port: int) -> int:
async def configure_motor_stepper(self, port: int) -> None:
await self.configure_motor(port, motor.StepperConfig())

async def move_motor(self, port: int, amount: int, mode: int=motor.POWER) -> None:
Expand Down
8 changes: 4 additions & 4 deletions hedgehog/client/sync_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,16 +166,16 @@ def set_digital_output(self, port: int, level: bool) -> None:
def get_io_config(self, port: int) -> int:
return self._call_safe(lambda: self.client.get_io_config(port))

def configure_motor(self, port: int, config: motor.Config) -> int:
def configure_motor(self, port: int, config: motor.Config) -> None:
self._call_safe(lambda: self.client.configure_motor(port, config))

def configure_motor_dc(self, port: int) -> int:
def configure_motor_dc(self, port: int) -> None:
self._call_safe(lambda: self.client.configure_motor_dc(port))

def configure_motor_encoder(self, port: int, encoder_a_port: int, encoder_b_port: int) -> int:
def configure_motor_encoder(self, port: int, encoder_a_port: int, encoder_b_port: int) -> None:
self._call_safe(lambda: self.client.configure_motor_encoder(port, encoder_a_port, encoder_b_port))

def configure_motor_stepper(self, port: int) -> int:
def configure_motor_stepper(self, port: int) -> None:
self._call_safe(lambda: self.client.configure_motor_stepper(port))

def move_motor(self, port: int, amount: int, mode: int=motor.POWER) -> None:
Expand Down
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

setup(
name='hedgehog-client',
version='0.9.0rc5',
version='0.9.0',
description='Client library for communicating with Hedgehog Robot Controllers',
long_description=long_description,
url="https://github.com/PRIArobotics/HedgehogClient",
Expand All @@ -46,7 +46,7 @@
# your project is installed. For an analysis of "install_requires" vs pip's
# requirements files see:
# https://packaging.python.org/en/latest/requirements.html
install_requires=['concurrent-utils ~=0.2.0', 'hedgehog-protocol ~=0.8.0rc2',
install_requires=['concurrent-utils ~=0.2.0', 'hedgehog-protocol ~=0.9.0',
'hedgehog-utils[protobuf,zmq] ~=0.7.0rc1', 'pycreate2'],

# You can install these using the following syntax, for example:
Expand Down
2 changes: 1 addition & 1 deletion tests/test_async_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ async def test_get_imu_pose(self, connect_dummy):

@pytest.mark.asyncio
async def test_speaker_action(self, connect_dummy):
frequency = 0
frequency = None
async with connect_dummy(Commands.speaker_action, frequency) as client:
assert await client.set_speaker(frequency) is None

Expand Down
2 changes: 1 addition & 1 deletion tests/test_sync_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,7 @@ def test_get_imu_pose(self, connect_dummy):
assert client.get_imu_pose() == (x, y, z)

def test_speaker_action(self, connect_dummy):
frequency = 0
frequency = None
with connect_dummy(Commands.speaker_action, frequency) as client:
assert client.set_speaker(frequency) is None

Expand Down

0 comments on commit 677a433

Please sign in to comment.